package com.party.mobile.web.dto.crowdfund.output;

import com.party.core.model.activity.CrowfundResources;
import com.party.core.model.crowdfund.CrowdfundEvent;
import org.springframework.beans.BeanUtils;

import java.util.Date;
import java.util.List;

/**
 * 众筹主题输出视图
 * Created by wei.li.
 *
 * @date 2018/1/16 0016
 * @time 16:09
 */
public class CrowdfundEventOutput {
    //编号
    private String id;
    // 标题
    private String title;
    // 图片
    private String pic;
    // 活动开始时间
    private Date startTime;
    // 结束时间
    private Date endTime;
    // 价格
    private Float price;
    // 活动详情
    private String content;
    //报名相关
    private String applyRelated;
    //参赛标准
    private String matchStandard;
    // 跑马灯
    private List<CrowfundResources> picList;
    // 视频
    private CrowfundResources video;
    // 创建者编号
    private String authorId;
    // 创建者名称
    private String authorName;
    // 创建者图像
    private String authorLogo;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getPic() {
        return pic;
    }

    public void setPic(String pic) {
        this.pic = pic;
    }

    public Date getStartTime() {
        return startTime;
    }

    public void setStartTime(Date startTime) {
        this.startTime = startTime;
    }

    public Date getEndTime() {
        return endTime;
    }

    public void setEndTime(Date endTime) {
        this.endTime = endTime;
    }

    public Float getPrice() {
        return price;
    }

    public void setPrice(Float price) {
        this.price = price;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getApplyRelated() {
        return applyRelated;
    }

    public void setApplyRelated(String applyRelated) {
        this.applyRelated = applyRelated;
    }

    public String getMatchStandard() {
        return matchStandard;
    }

    public void setMatchStandard(String matchStandard) {
        this.matchStandard = matchStandard;
    }

    public List<CrowfundResources> getPicList() {
        return picList;
    }

    public void setPicList(List<CrowfundResources> picList) {
        this.picList = picList;
    }

    public CrowfundResources getVideo() {
        return video;
    }

    public void setVideo(CrowfundResources video) {
        this.video = video;
    }

    public String getAuthorId() {
        return authorId;
    }

    public void setAuthorId(String authorId) {
        this.authorId = authorId;
    }

    public String getAuthorName() {
        return authorName;
    }

    public void setAuthorName(String authorName) {
        this.authorName = authorName;
    }

    public String getAuthorLogo() {
        return authorLogo;
    }

    public void setAuthorLogo(String authorLogo) {
        this.authorLogo = authorLogo;
    }

    public static CrowdfundEventOutput transform(CrowdfundEvent crowdfundEvent){
        CrowdfundEventOutput crowdfundEventOutput = new CrowdfundEventOutput();
        BeanUtils.copyProperties(crowdfundEvent, crowdfundEventOutput);
        return crowdfundEventOutput;
    }
}
